<?php
namespace App\Model;

use PhalApi\Model\NotORMModel as NotORM;

class WALLETWITHDRAW extends NotORM
{

    protected function getTableName($id)
    {
        return 'wallet_withdraw';
    }

    public function getAddressid($ico, $from_wallet_user_id, $toaddress) {
        $data = $this->getORM()->where(['ico' => $ico])->where(['from_wallet_user_id' => $from_wallet_user_id])->where(['toaddress' => $toaddress])->fetchOne();
        if(!empty($data))
            return $data;
    }

    public function getAllIoc()
    {
        $data = $this->getORM()->fetchAll();
        if(!empty($data))
            return $data;
    }

}